package cn.gzsxt.music.controller;

import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import cn.gzsxt.music.service.LableService;

@Controller
@Scope("request")
@RequestMapping(value="/lable")
public class LableController {
	
	@Autowired
	private LableService service;
	
	@RequestMapping("getLables")
	@ResponseBody
	public List<Map<String, Object>> getLable(){
		return service.getAllLables();		
	}
	
	@RequestMapping("toLables")
	@ResponseBody
	public String getLable(String song_label){
		System.out.println(song_label);
		return service.toLables(song_label);		
	}
	
}
